let express = require("express");
const mainApp = getNewApp();
let cors = require("cors");
mainApp.use(cors());
mainApp.use(express.json({ limit: "1000mb" }));

// 获取新的 router
function getNewRouter() {
  return express.Router();
}

// 获取新的 app
function getNewApp() {
  return express();
}

module.exports = {
  mainApp,
  getNewApp,
  getNewRouter,
};
